<?php
/**
 * 登录控制器
 */
class User extends Controller
{
	public function Password()
	{
		echo "用户修改密码";
	}

	public function Edit()
	{
		echo "用户修改资料";
	}

	public function userlist()
	{

		// $db = new Db('user');

		// $data = $db->select();

		$data = (new UserModel)->get_user_info();
		// $this->data = $data;
		// var_dump($data);
		//分配变量
		$this->assign('user',$data);
		$this->assign('title',"学并思");
		$this->assign('age',18);
		$this->display();
	}

	public function test()
	{
		$arr = ['age'=>18,'name'=>'xuebingsi'];

		extract($arr);


		// $arr['age'];
		var_dump($age);
	}
}
